
            <tr>
                <td>上传附件：</td>
                <td class="td2">
                    <link href="{$this->setting['weburl']}/content/swfupload/swfupload.css" rel="stylesheet" type="text/css"/>
                    <script type="text/javascript" src="{$this->setting['weburl']}/content/swfupload/swfupload.js"></script>
                    <script type="text/javascript" src="{$this->setting['weburl']}/content/swfupload/handlers.js"></script>
                    <script type="text/javascript">
                        $( function () {
                            var upload = new uploadPlugin({
                                'file_size_limit':"{$this->setting[ 'upsize' ]} MB",
                                'file_types':"{$this->setting[ 'uptype' ]}",
                                'cookie_auth':"{echo md6( APP_COOKIE, 'encode' )}"
                            });
                            upload.init();
                        });
                    </script>
                    <div id="file_upload">
                        <div id="SWFUploadButton"></div>
                        <button class="btn btn-inverse">选择文件</button>
                    </div>
                    <p style="padding-top: 10px;">可用扩展名: {$this->setting[ 'uptype' ]} 单个文件大小: {$this->setting[ 'upsize' ]} MB</p>
                </td>
            </tr>
        <!--{if $result['attachments']}-->
            <script src="{$this->themesURL}/js/attach.js" type="text/javascript"></script>
            <tr>
                <th><b>已上传附件</b></th>
                <td class="td2" style="border-right: none;">
                {eval $attachments = $this->model->getAttachment( $result['id'] )}
                        <table cellpadding="1" cellspacing="1" width="100%" border="0">
                        <!--{loop $attachments $v}-->
                            <tr class="attach">
                                <td class="name" style="cursor: pointer">{$v['filename']}</td>
                                <td width="20%">{echo formatDate($v['dateline'])}上传</td>
                                <td width="10%">{$v['filesize']}</td>
                                <td width="28%">
                                    <a class="add_attach btn btn-mini btn-success" href="" title="添加附件到文章内容中">添加到内容</a>
                                    <a class="thumb_attach{$v['isImage'] ? '' : ' disabled'} btn btn-mini btn-info" title="设置为缩略图" href="">缩略图</a>
                                    <a class="del_attach btn btn-mini btn-danger" title="删除附件" href="{$this->url('attachment', 'del', array('id' => $v['id']) )}">删除</a>
                                </td>
                                <td style="display: none;">
                                    <div class="id">{$v['id']}</div>
                                    <div class="img">{$v['isImage']}</div>
                                    <div class="file">{$v['filepath']}</div>
                                 </td>
                            </tr>
                        <!--{/loop}-->
                        </table>
                </td>
            </tr>
       <!--{/if}-->
